package day04;

import java.util.Scanner;

public class test03 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int t = n;
        int m = 0;
        int g;

        while (n != 0){
            g = n % 10;
            n = n / 10;//!!!
            m = m * 10 + g;
        }
        System.out.println(m);

        if(t == m){
            System.out.println("true");
        }else {
            System.out.println("false");
        }

    }
}
